Registers are special, high-speed storage devices used for processing data within a microprocessor of modern computers. Data or the address of the memory location where that data is located is stored in a register before the data is processed and the subsequent result of the processing or the address of the memory location where that result is located is also stored in a register. The number of registers that a microprocessor has and the number of bits that each register can store are two of various parameters that determine the power and speed of any given microprocessor. As an example, a 64-bit microprocessor is one in which each register is 64 bits wide meaning that each microprocessor instruction can manipulate up to 64 bits of data in any given instruction cycle as opposed to a 32-bit microprocessor which can only manipulate a maximum of 32 bits of data in any given instruction cycle.
Superscalar architecture microprocessors can execute more than one instruction per clock cycle. During execution, each of the concurrent instructions or groups of parallel instructions must use different registers. In such microprocessors, the concept of mapping physical registers is helpful in maintaining the separation between groups of registers. For each parallel processing set of instructions active on the microprocessor, each architecture register assigned to that process or program is mapped to a physical register. In addition, maintaining a physical register mapping table (PRMT) and an architecture register mapping table (ARMT), which records the mapping relationships between the physical registers and the architecture registers, enable faster operation. While the mapping information in the ARMT is also available in the PRMT, due to the smaller size of the ARMT the microprocessor can search the ARMT faster for the physical register number corresponding to the architecture register number than it could search the PRMT for the same information.
If an exception or branch misprediction does occur, entries in the ARMT must be recovered to their state just before that abnormal condition occurred. Since the PRMT contains more complete information than does the ARMT, the PRMT is first restored to its state just before the abnormal condition. Then, the ARMT is restored from information in the PRMT.